from django.contrib import admin
from .models import StockData

@admin.register(StockData)
class StockDataAdmin(admin.ModelAdmin):
    list_display = ('ts_code', 'trade_date', 'open', 'high', 'low', 'close')  # 显示的字段
    list_filter = ('ts_code', 'trade_date')  # 过滤器
    search_fields = ('ts_code',)  # 搜索字段
   
